
	

/*********************************************************
  Run the analysis: focus on shares volume (LR2) for now 
*********************************************************/

use "D:\Dropbox\Work - RA\! (2023.12.18) Update\(2.8.2024) Modified\C_3_Filtered_data.dta", replace

cd "D:\Dropbox\Work - RA\! (2025.03.03) Final replication code for RFS"
xtset PERMNO date


* Sample: All common stocks WITH return & sigma 
global filter "if !missing(r_t1,sigma_s2_wm) & inlist(SHRCD,10,11) & year*100+month>=200611"

sum abs_oib_mth_s2_wm $filter
sum abs_ns_oib_mth_s2_wm $filter


* Additional tests (without standardization)
eststo clear 
	
	eststo, title((1)): asreg r_t r_t1_lag1-r_t1_lag12 $filter, fmb
	eststo, title((5)): asreg r_t r_t1_lag1-r_t1_lag12 abs_ns_oib_mth_s2_wm abs_ns_oib_mth_s2_wmXr_t1 $filter, fmb
	eststo, title((3)): asreg r_t r_t1_lag1-r_t1_lag12 ns_sigma_s2_wm ns_sigma_s2_wmXr_t1 $filter, fmb        

	* Other redundant columns are deleted
	esttab using "Result_Table_9.csv", replace t  nodepvar label legend mtitles star(* 0.10 ** 0.05 *** 0.01) ///
	title(Adding lagged returns wo standardization) ///
	r2 indicate(`r(indicate_fe)') ///
	addnotes(Sample: common stocks during 2006 November ~ 2020 December)

